Global Variable

Global variables are similar to call variables, but they do not change as new calls are made (i.e., their lifetime is not restricted to the duration of a call).

Syntax:

var.global.<Variable Name> 

where, <Variable Name> specifies the name of the global variable.

For example:

Store a value in a global variable: Stores the Priority header of the INVITE with ‘company’ in the host part of the From header:
MessageManipulations 0 = 0, Invite.Request, header.from.url.host == ‘company’, var.global.My-Global, 2, header.priority, 0;
Use the stored value: Assigns the same priority as the INVITE request to SUBSCRIBE requests arriving with 'company' in the host part of the From header:
MessageManipulations 0 = 0, Subscribe.request, header.from.url.host == ‘company’, header.priority, 0, var.global.My-Global, 0;

The following table provides additional configuration examples of using variables in Message Manipulation rules.

Example of Global Variables

Message Type

Action
Subject

Action Type

Action Value

invite

var.global.My-Global

Modify

'Custom UA'